01. The jQuery Library & Ajax
Ajax Call with $.ajax()?
jQuery is an incredibly popular JavaScript library that provides a lot of functionality right out of the box. It was created a number of years ago back when browsers hadn't joined together to standardize on functionality. jQuery made life easier for developers that were building websites that had to function in all of the major browsers by providing a unified interface. The developer would use jQuery-specific functions and then jQuery would figure out what code to run depending on the browser that was being used.
jQuery is just JavaScript, so you'd download a current version and link to it with a regular <script>
tag. Once it's been included it on the page, you've got this powerhouse of functionality right at your fingertips.
Now that browsers have pretty much aligned, jQuery's usage is not as necessary as it was several years ago. However, one powerful tool that it provides is it's ajax()
method.
As its name suggests, jQuery's ajax()
method is used to handle all asynchronous requests.
Let's see it in action.
Wanna Learn jQuery?
jQuery is incredibly popular and used by hundreds of thousands of sites. If you want dig deeper into this cool JavaScript library, check out our Intro to jQuery course.